<?php 
include '../config/DBConnect.php';

$sql="SELECT * From thongbao ORDER BY id DESC LIMIT 5 ";
$rs=mysql_query($sql);
$data=array();
if ($rs) {
 while ($rows=mysql_fetch_array($rs)) {
    $test = array();
    $test['id']=$rows['id'];
    $test['tieude']=$rows['tieude'];
    array_push($data, $test);
} 
//var_dump($data);
}


?>
<div class="rcontent">
  <div class="l_title1">
    <h3>Lịch</h3>
    <div id = "thoitiet" >
     Đây là thơi tiết
 </div>
</div>
<div class="l_title1">
    <h3>Video</h3>
    <div id="video"> 
       Vi Deo
   </div>           
</div>
<div class="l_title1">
    <h3>Thời Tiết</h3>
    <div id="video"> 
       Thời tiết đây
   </div>           
</div>
</div>
<div class="content">
    <div id="slide" >
        <div id="title_thongbao">
            <h2>Thông Báo!</h2><br />

            <table>
            <?php 
            foreach ($data as $val) {
            
                ?>
                <tr>
                    <td align="left" style="foat:left; "><ul><li style="margin-top:-3px;"><b><a style="font-size:16px;" href="../thongbao/chitiet_thongbao.php?id=<?php echo $val['id'] ?>"><?php echo $val['tieude'] ; ?></a></b></li></ul></td>
                </tr>
                <?php
            }
             ?>
               
            </table>	
        </div>
    </div>
